MenuBitmaps Bitmap Menus Script Form1, Picture1 wwwww System Picture3 Script Picture1 System Picture3 Script Picture1 wwwwwwwww wwwwwwwwww wwwwwwwww wwwwwwwww wwwwwwwwww DDDDDDDDDGw wpwww wwwwwwwww wpwwwww wwwwwp ffffffff` DDDDDDDD wpwwwwwww fffffffff`wwww wwwwwwwp fffffffff` wpwwwwwwwww fffffffff wwwwwwwwwpw fffffffff wpwwwwwwwwwwpw fffffffff` wwwwwww fffffffff` pwwwpwwwwwwpw fffffffff wwwww fffffffff wwwpwpwwwwpw fffffffff` fffffffff`ww wwwpwpwwpw fffffffff wwwwwwpw wwwww fffffffff` wwwwpw fffffffff fffffffff fffffffff` System Picture3 Script Picture2 System Picture1 wwwwwwwwwwwwww wwwwwwwwwwwwww wwwwwwwwwww wwwwwwwwwwww System Picture3 Script Picture1 wwwwwwwp pwwwwp wwwwwww wwwww wwwwp wwwwwwx wwwww System Picture3 Script Bitmaps &Static SubMenu Static Bitmap 0 SubMenu Static Bitmap 1 SubMenu Static Bitmap 2 SubMenu Static Bitmap 3 SubMenu Static Bitmap 4 DynamicBitmaps &Dynamic MSubMenu Dynamic Bitmap 0 MSubMenu Dynamic Bitmap 1 MSubMenu Dynamic Bitmap 2 MSubMenu Dynamic Bitmap 3 MSubMenu Dynamic Bitmap 4 CreateDynamic &Create Dynamic Bitmaps! GetMenul GetSubMenu hMenu GetMenuItemIDQ ModifyMenu nPosition wFlags# wIDNewItem lpNewItem SetMenuItemBitmaps hBitmapUnchecked hBitmapCheckedV TrackPopupMenub GetSystemMenu revert MF_BITMAPH CLR_MENUBAR FALSE TextItems LastSelection~ CurrentText. Form_Loadb Static_Bitmaps_To_Menus MSubMenu Caption picture3" FontName FontSize SubMenu_Click Index Form_Paint SubMenu CheckedU MSubMenu_Click Create_Dynamic_Menu_Bitmaps Width2 Height| BackColor hSubMenu Picture Image menuId picture2 CreateDynamic_Click CreateDynamicL enabled picture1B Form_MouseUp Button Shift ScaleMode InPixels ScaleWidth ScaleHeight Window API Function Declarations usero usero Form_Load * Obtain handle to the Forms top level menu * Initial String with text displayed when menus are selected.u * (Just so something happens when a menu is selected.) Writing Tools" Fonts" Books/Notes" Printers Computers" * Set "Dynamic" menus submenus initial Menu text values * to Fontname + Fontsize of each menu item SubMenu_Click * Set text to that of selected menu item and * display the new text * Uncheck last selected item and check seledted item Check selected menuk UnCheck last selected menu Save current selection MSubMenu_Click * Reset forms FontSize to selected fontsizeu * and redisplay current text * Uncheck last selected item and check selected item Create_Dynamic_Menu_Bitmaps * Set the width and height of the Picture controls * based on their corresponding Menu items caption, * and the Picture controls Font and FontSize.t * DoEvents() is neccessary to make new dimension * values to take affect prior to exiting this Sub. * Set Backcolor of Picture control to that of the * current system Menu Bar color, so Dynamic bitmaps * will appear as normal menu items when menu bar * color is changed via the control panel * Print Text onto Picture control. This text will * become the bitmap. * Obtain handle Second submenu * - Set picture controls backgroup picture (Bitmap) to its Image. Can't use the Image bitmap directly for some reason. * - Get ID of sub menu * - Replace menu text with bitmap from corresponding picture control * - Replace bitmap for menu check mark with custom check mark bitmap Form_Paint CreateDynamic_Click Static_Bitmaps_To_Menus * Obtain handle to first submenu * - Get ID of each sub menub * - Replace menu text with bitmap from corresponding picture control * - Replace bitmap for menu check mark with custom check mark bitmap Form_MouseUp